﻿<%@ Page Language="C#" MasterPageFile="~/Common/Master/FrameMain.master" AutoEventWireup="true" Theme="SkinFile" Inherits="DocManger_List" Title="无标题页" Codebehind="List.aspx.cs" %>

<%@ Register src="../Common/Controls/Footer.ascx" tagname="Footer" tagprefix="uc2" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="Server">
     <script type="text/javascript" src="../common/Js/menu.js"></script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="Server">
    <asp:HiddenField ID="hidSelectDirIDs" runat="server" Value=""></asp:HiddenField>
    <asp:HiddenField ID="hidSelectDocIDs" runat="server" Value=""></asp:HiddenField>
    <asp:HiddenField ID="hidMyDocIDs" runat="server" />
    <asp:HiddenField ID="hidMyDirIDs" runat="server" />
    <div id="toolbar">
        <ul>
            <li id="liAdd" runat="server">
            <div style="width: 0px; height: 0px; position: absolute;">
                    <div id="divmenu" style="display: none;">
                        <asp:HyperLink ID="lnkAddDoc" runat="server" NavigateUrl="javascript:;">文档</asp:HyperLink>
                        <asp:HyperLink ID="lnkAddDir" runat="server" NavigateUrl="javascript:;">目录</asp:HyperLink>
                    </div>
            </div>
            <a id="lnkAdd" href="javascript:showMenu('lnkAdd');"><span><b style="background-image: url(../common/images/icons/addnew.gif);">
                &nbsp;</b>
                <asp:Literal ID="Literal1" runat="server" Text="增加"></asp:Literal></span></a></li>
           <li id="liDelete" runat="server"><a id="lnkDelete" runat="server" href="javascript:go()"><span><b style="background-image: url(../common/images/icons/DELETE.gif);">
                &nbsp;</b>
                <asp:Literal ID="Literal2" runat="server" Text="删除"></asp:Literal></span></a></li>
           <li><a id="lnkMove" runat="server" href="javascript:go()"><span><b style="background-image: url(../common/images/icons/move.gif);">
                &nbsp;</b>移动</span> </a></li>
            <li><a id="lnkUpper" runat="server" href="javascript:go()"><span><b style="background-image: url(../common/images/common/UpperFolder.gif);">
                &nbsp;</b>上一级</span> </a></li>
        </ul>
    </div>
    
    <div id="head">
        <div class="left"><asp:Label ID="Label7" runat="server" Text="当前目录：" Font-Bold="True"></asp:Label>
            [&nbsp;<asp:Label ID="lblDir" runat="server" Text="Label"></asp:Label>
            ]</div>
        <div class="right"><asp:LinkButton ID="btnDisplay" runat="server" OnClick="btnDisplay_Click">隐藏目录</asp:LinkButton>
            <asp:DropDownList ID="drpPager" runat="server" AutoPostBack="True" OnSelectedIndexChanged="drpPager_SelectedIndexChanged">
            </asp:DropDownList></div>
    </div>
    <div id="list">
        <asp:GridView ID="gvList" runat="server" AutoGenerateColumns="False" EnableViewState="False"
            SkinID="gridView" Width="100%" AllowPaging="True" OnRowDataBound="gvList_RowDataBound">
            <Columns>
                <asp:TemplateField>
                    <ItemStyle CssClass="sp" />
                    <HeaderStyle CssClass="sp" />
                </asp:TemplateField>
                <asp:TemplateField HeaderText="选择">
                    <ItemTemplate>
                        <asp:CheckBox ID="chkSelect" runat="server" />
                    </ItemTemplate>
                    <HeaderTemplate>
                        <asp:CheckBox ID="chkSelectAll" runat="server" />
                    </HeaderTemplate>
                    <ItemStyle CssClass="chk" />
                    <HeaderStyle CssClass="chk" />
                </asp:TemplateField>
                <asp:TemplateField HeaderText="名称">
                    <ItemTemplate>
                        <asp:HyperLink ID="lnkName" runat="server" NavigateUrl="#" Text='<%# Eval("Name") %>'></asp:HyperLink>
                    </ItemTemplate>
                    <ItemStyle HorizontalAlign="Left" />
                    <HeaderStyle HorizontalAlign="Left" />
                </asp:TemplateField>
                <asp:TemplateField HeaderText="类型">
                    <ItemTemplate>
                        <asp:Image ID="imgType" runat="server" ImageUrl='<%# BindType((int)Eval("Type")) %>' />
                        <asp:HiddenField ID="hidType" runat="server" Value='<%# Eval("Type") %>' />
                    </ItemTemplate>
                </asp:TemplateField>
                <asp:TemplateField HeaderText="权限">
                    <ItemTemplate>
                        <asp:HyperLink ID="lnkSetRight"  runat="server">设置</asp:HyperLink>
                    </ItemTemplate>
                </asp:TemplateField>
                <asp:TemplateField HeaderText="创建者">
                    <ItemTemplate>
                        <asp:Literal ID="Literal1" runat="server" Text='<%# Eval("CreatorName") %>'></asp:Literal><asp:HiddenField
                            ID="hidCreatorID" Value='<%# Eval("CreatorID") %>' runat="server" />
                    </ItemTemplate>
                </asp:TemplateField>
                <asp:TemplateField HeaderText="创建时间">
                    <ItemTemplate>
                        <asp:Literal ID="Literal2" runat="server" Text='<%# Eval("InputTime") %>'></asp:Literal>
                    </ItemTemplate>
                </asp:TemplateField>
            </Columns>            
            <PagerSettings Visible="False" />
        </asp:GridView>
    </div>    
    <uc2:Footer ID="Footer1" runat="server" />
    <div id="toolbar_bottom" >
    <asp:Button ID="btnDelete" runat="server" Text="删除" OnClick="btnDelete_Click" />
        <asp:Button ID="btnUpper" runat="server" Text="上级目录" OnClick="btnUpper_Click" />
        <asp:Button ID="btnRefresh" runat="server" OnClick="btnRefresh_Click" Text="Button" CssClass="hide" />
    </div>
    
</asp:Content>
